From ca29668a5d389ea0d857506c183a88dc9c027b70 Mon Sep 17 00:00:00 2001 From: Aleksey Kladov Date: Thu, 19 May 2016 03:02:41 +0300 Subject: [PATCH] fix more tests with auto refactoring --- tests/test_cargo_bench.rs | 12 ++++++------ tests/test_cargo_test.rs | 23 ++++++++++++----------- 2 files changed, 18 insertions(+), 17 deletions(-) diff --git a/tests/test_cargo_bench.rs b/tests/test_cargo_bench.rs index eb1c90a73..f63c663ac 100644 --- a/tests/test_cargo_bench.rs +++ b/tests/test_cargo_bench.rs @@ -987,17 +987,17 @@ test!(test_bench_multiple_packages { assert_that(p.cargo_process("bench").arg("-p").arg("bar").arg("-p").arg("baz"), execs().with_status(0) - .with_stdout_contains("\ -[RUNNING] target[..]release[..]bbaz-[..] - + .with_stderr_contains("\ +[RUNNING] target[..]release[..]bbaz-[..]") + .with_stdout_contains(" running 1 test test bench_baz ... bench: 0 ns/iter (+/- 0) test result: ok. 0 passed; 0 failed; 0 ignored; 1 measured ") - .with_stdout_contains("\ -[RUNNING] target[..]release[..]bbar-[..] - + .with_stderr_contains("\ +[RUNNING] target[..]release[..]bbar-[..]") + .with_stdout_contains(" running 1 test test bench_bar ... bench: 0 ns/iter (+/- 0) diff --git a/tests/test_cargo_test.rs b/tests/test_cargo_test.rs index d40271580..81ac9d3f5 100644 --- a/tests/test_cargo_test.rs +++ b/tests/test_cargo_test.rs @@ -1855,27 +1855,28 @@ test!(no_fail_fast { "#); assert_that(p.cargo_process("test").arg("--no-fail-fast"), execs().with_status(101) - .with_stdout_contains("\ + .with_stderr_contains("\ [COMPILING] foo v0.0.1 ([..]) [RUNNING] target[..]foo[..] - +[RUNNING] target[..]test_add_one[..]") + .with_stdout_contains(" running 0 tests test result: ok. 0 passed; 0 failed; 0 ignored; 0 measured -[RUNNING] target[..]test_add_one[..] ") + .with_stderr_contains("\ +[RUNNING] target[..]test_sub_one[..] +[DOCTEST] foo") .with_stdout_contains("\ test result: FAILED. 1 passed; 1 failed; 0 ignored; 0 measured -[RUNNING] target[..]test_sub_one[..] running 1 test test sub_one_test ... ok test result: ok. 1 passed; 0 failed; 0 ignored; 0 measured -[DOCTEST] foo running 1 test test sub_one_0 ... ok @@ -1929,16 +1930,16 @@ test!(test_multiple_packages { assert_that(p.cargo("test").arg("-p").arg("d1").arg("-p").arg("d2"), execs().with_status(0) - .with_stdout_contains("\ -[RUNNING] target[..]debug[..]d1-[..] - + .with_stderr_contains("\ +[RUNNING] target[..]debug[..]d1-[..]") + .with_stdout_contains(" running 0 tests test result: ok. 0 passed; 0 failed; 0 ignored; 0 measured ") - .with_stdout_contains("\ -[RUNNING] target[..]debug[..]d2-[..] - + .with_stderr_contains("\ +[RUNNING] target[..]debug[..]d2-[..]") + .with_stdout_contains(" running 0 tests test result: ok. 0 passed; 0 failed; 0 ignored; 0 measured -- 2.30.2